﻿using Admin.NET.Core;
namespace Admin.NET.Application.Entity;

/// <summary>
/// 教师
/// </summary>
[SugarTable("Teacher","教师")]
[SugarIndex("unique_teacher_username", nameof(Teacher.UserName), OrderByType.Desc, true)]
[SugarIndex("unique_teacher_name", nameof(Teacher.Name), OrderByType.Desc, true)]
public class Teacher  : EntityBase
{
    /// <summary>
    /// 序号
    /// </summary>
    [SugarColumn(ColumnName = "Xuhao", ColumnDescription = "序号", Length = 32)]
    public string? Xuhao { get; set; }
    
    /// <summary>
    /// 校内编号
    /// </summary>
    [SugarColumn(ColumnName = "Code", ColumnDescription = "校内编号", Length = 32)]
    public string? Code { get; set; }
    
    /// <summary>
    /// 姓名
    /// </summary>
    [Required]
    [SugarColumn(ColumnName = "Name", ColumnDescription = "姓名", Length = 32)]
    public string Name { get; set; }
    
    /// <summary>
    /// 是否在校
    /// </summary>
    [Required]
    [SugarColumn(ColumnName = "IsAtSchool", ColumnDescription = "是否在校")]
    public bool IsAtSchool { get; set; }
    
    /// <summary>
    /// 是否在籍
    /// </summary>
    [Required]
    [SugarColumn(ColumnName = "IsAtBook", ColumnDescription = "是否在籍")]
    public bool IsAtBook { get; set; }
    
    /// <summary>
    /// 电话
    /// </summary>
    [SugarColumn(ColumnName = "Tel", ColumnDescription = "电话", Length = 32)]
    public string? Tel { get; set; }
    
    /// <summary>
    /// 用户名
    /// </summary>
    [Required]
    [SugarColumn(ColumnName = "UserName", ColumnDescription = "用户名", Length = 32)]
    public string UserName { get; set; }
    
}
